# Maintainer: Alexey Pavlov <alexpux@gmail.com>

_realname=orc

pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=0.4.19
pkgrel=1
pkgdesc="The Oild Runtime Compiler (mingw-w64)"
arch=('any')
url="http://code.entropywave.com/projects/orc/"
license=("custom")
makedepends=("${MINGW_PACKAGE_PREFIX}-gcc" "${MINGW_PACKAGE_PREFIX}-pkg-config")
options=('strip' 'staticlibs')
source=("http://gstreamer.freedesktop.org/src/orc/${_realname}-${pkgver}.tar.gz")
md5sums=('2cacea6271aade6d592fe1622a136f19')

prepare() {
  cd "${srcdir}/${_realname}-${pkgver}"
}

build() {
  mkdir -p "${srcdir}/build-${MINGW_CHOST}"
  cd "${srcdir}/build-${MINGW_CHOST}"
  ../${_realname}-${pkgver}/configure \
    --prefix=${MINGW_PREFIX} \
    --build=${MINGW_CHOST} \
    --host=${MINGW_CHOST} \
    --target=${MINGW_CHOST} \
    --disable-static
  make
}

package() {
  cd "${srcdir}/build-${MINGW_CHOST}"
  make DESTDIR="${pkgdir}" install
}
